.class Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;
.super Ljava/lang/Object;
.source "FootprintDetailEditActivity.java"

# interfaces
.implements Landroid/view/View$OnClickListener;


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;


# direct methods
.method constructor <init>(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;)V
    .locals 0
    .parameter

    .prologue
    .line 908
    iput-object p1, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onClick(Landroid/view/View;)V
    .locals 12
    .parameter "arg0"

    .prologue
    const-wide v9, 0x412e848000000000L

    const/4 v8, 0x1

    const-string v11, "InputLocation"

    .line 863
    new-instance v4, Landroid/content/Intent;

    const-string v5, "com.htc.android.locationpicker"

    invoke-direct {v4, v5}, Landroid/content/Intent;-><init>(Ljava/lang/String;)V

    .line 865
    .local v4, intent:Landroid/content/Intent;
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    invoke-virtual {v5}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->getResources()Landroid/content/res/Resources;

    move-result-object v5

    const v6, 0x7f020097

    invoke-virtual {v5, v6}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v3

    check-cast v3, Landroid/graphics/drawable/BitmapDrawable;

    .line 867
    .local v3, icon:Landroid/graphics/drawable/BitmapDrawable;
    invoke-virtual {v3}, Landroid/graphics/drawable/BitmapDrawable;->getBitmap()Landroid/graphics/Bitmap;

    move-result-object v0

    .line 868
    .local v0, bitmap:Landroid/graphics/Bitmap;
    const-string v5, "PickerIcon"

    invoke-virtual {v4, v5, v0}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Landroid/os/Parcelable;)Landroid/content/Intent;

    .line 872
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    #getter for: Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->mFootprint:Lcom/htc/android/footprints/vo/Footprint;
    invoke-static {v5}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->access$100(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;)Lcom/htc/android/footprints/vo/Footprint;

    move-result-object v5

    iget v5, v5, Lcom/htc/android/footprints/vo/Footprint;->mLatitude:I

    if-nez v5, :cond_1

    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    #getter for: Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->mFootprint:Lcom/htc/android/footprints/vo/Footprint;
    invoke-static {v5}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->access$100(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;)Lcom/htc/android/footprints/vo/Footprint;

    move-result-object v5

    iget v5, v5, Lcom/htc/android/footprints/vo/Footprint;->mLongitude:I

    if-nez v5, :cond_1

    .line 873
    const-string v5, "InputLocation"

    const/4 v5, 0x4

    invoke-virtual {v4, v11, v5}, Landroid/content/Intent;->putExtra(Ljava/lang/String;I)Landroid/content/Intent;

    .line 883
    :goto_0
    const-string v5, "PickerMode"

    invoke-virtual {v4, v5, v8}, Landroid/content/Intent;->putExtra(Ljava/lang/String;I)Landroid/content/Intent;

    .line 884
    const-string v5, "PickerPanelStyle"

    const/16 v6, 0x8

    invoke-virtual {v4, v5, v6}, Landroid/content/Intent;->putExtra(Ljava/lang/String;I)Landroid/content/Intent;

    .line 886
    const-string v5, "PickerHintFlag"

    const/4 v6, 0x5

    invoke-virtual {v4, v5, v6}, Landroid/content/Intent;->putExtra(Ljava/lang/String;I)Landroid/content/Intent;

    .line 887
    const-string v5, "PickerHintMsg"

    iget-object v6, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    #getter for: Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->mFootprint:Lcom/htc/android/footprints/vo/Footprint;
    invoke-static {v6}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->access$100(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;)Lcom/htc/android/footprints/vo/Footprint;

    move-result-object v6

    iget-object v6, v6, Lcom/htc/android/footprints/vo/Footprint;->mName:Ljava/lang/String;

    invoke-virtual {v4, v5, v6}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 888
    const-string v5, "PickerReturnType"

    const/16 v6, 0x9

    invoke-virtual {v4, v5, v6}, Landroid/content/Intent;->putExtra(Ljava/lang/String;I)Landroid/content/Intent;

    .line 890
    const-string v5, "PickerAlertConnectionFailed"

    iget-object v6, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    invoke-static {v6}, Lcom/htc/android/footprints/utils/SettingInfo;->getInstance(Landroid/content/Context;)Lcom/htc/android/footprints/utils/SettingInfo;

    move-result-object v6

    iget-boolean v6, v6, Lcom/htc/android/footprints/utils/SettingInfo;->showConnectionFailedAlert:Z

    invoke-virtual {v4, v5, v6}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Z)Landroid/content/Intent;

    .line 892
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    #getter for: Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->locationText:Landroid/widget/TextView;
    invoke-static {v5}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->access$1600(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;)Landroid/widget/TextView;

    move-result-object v5

    const v6, 0x7f0a003c

    invoke-virtual {v5, v6}, Landroid/widget/TextView;->setText(I)V

    .line 895
    :try_start_0
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    iget-object v5, v5, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->mService:Lcom/htc/android/footprints/ILocationAgentService;

    if-eqz v5, :cond_0

    .line 896
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    iget-object v5, v5, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->mService:Lcom/htc/android/footprints/ILocationAgentService;

    const/4 v6, 0x0

    invoke-interface {v5, v6}, Lcom/htc/android/footprints/ILocationAgentService;->setTimeoutNotify(Z)V
    :try_end_0
    .catch Landroid/os/RemoteException; {:try_start_0 .. :try_end_0} :catch_0

    .line 903
    :cond_0
    :goto_1
    :try_start_1
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    const/4 v6, 0x1

    #setter for: Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->isPickerRunning:Z
    invoke-static {v5, v6}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->access$1702(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;Z)Z

    .line 904
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    const/4 v6, 0x1

    invoke-virtual {v5, v4, v6}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->startActivityForResult(Landroid/content/Intent;I)V
    :try_end_1
    .catch Landroid/content/ActivityNotFoundException; {:try_start_1 .. :try_end_1} :catch_1

    .line 908
    :goto_2
    return-void

    .line 877
    :cond_1
    const-string v5, "PickerLatitude"

    iget-object v6, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    #getter for: Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->mFootprint:Lcom/htc/android/footprints/vo/Footprint;
    invoke-static {v6}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->access$100(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;)Lcom/htc/android/footprints/vo/Footprint;

    move-result-object v6

    iget v6, v6, Lcom/htc/android/footprints/vo/Footprint;->mLatitude:I

    int-to-double v6, v6

    div-double/2addr v6, v9

    invoke-virtual {v4, v5, v6, v7}, Landroid/content/Intent;->putExtra(Ljava/lang/String;D)Landroid/content/Intent;

    .line 878
    const-string v5, "PickerLongitude"

    iget-object v6, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    #getter for: Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->mFootprint:Lcom/htc/android/footprints/vo/Footprint;
    invoke-static {v6}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->access$100(Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;)Lcom/htc/android/footprints/vo/Footprint;

    move-result-object v6

    iget v6, v6, Lcom/htc/android/footprints/vo/Footprint;->mLongitude:I

    int-to-double v6, v6

    div-double/2addr v6, v9

    invoke-virtual {v4, v5, v6, v7}, Landroid/content/Intent;->putExtra(Ljava/lang/String;D)Landroid/content/Intent;

    .line 879
    const-string v5, "InputLocation"

    const/4 v5, 0x3

    invoke-virtual {v4, v11, v5}, Landroid/content/Intent;->putExtra(Ljava/lang/String;I)Landroid/content/Intent;

    goto :goto_0

    .line 898
    :catch_0
    move-exception v5

    move-object v1, v5

    .line 899
    .local v1, e:Landroid/os/RemoteException;
    invoke-virtual {v1}, Landroid/os/RemoteException;->printStackTrace()V

    goto :goto_1

    .line 905
    .end local v1           #e:Landroid/os/RemoteException;
    :catch_1
    move-exception v5

    move-object v2, v5

    .line 906
    .local v2, ex:Landroid/content/ActivityNotFoundException;
    iget-object v5, p0, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity$7;->this$0:Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;

    const/16 v6, 0x10

    invoke-virtual {v5, v6}, Lcom/htc/android/footprints/activity/FootprintDetailEditActivity;->showDialog(I)V

    goto :goto_2
.end method
